home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1998 May: Tool Chest / Dev.CD May 98 TC.toast / Tool Chest / Testing & Debugging / General tools / Report Error 2.0 / DialogUtilities.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-08-17  |  2.0 KB  |  60 lines  |  [TEXT/KAHL]

  1. /*================================================================================
  2.     DialogUtilities.h
  3.     
  4.     circa 1991 by Greg Anderson
  5.     greggor@apple.com
  6.     
  7.     FREE DISTRIBUTION--use and enjoy
  8.     
  9.     This file contains various and sundry dialog box utility routines
  10. ================================================================================*/
  11. #ifndef __DIALOGUTILITIES__
  12. #define __DIALOGUTILITIES__
  13.  
  14. #ifndef __TYPES__
  15. #include <Types.h>
  16. #endif
  17. #ifndef __DIALOGS__
  18. #include <Dialogs.h>
  19. #endif
  20.  
  21. /*
  22. // This is the structure of an item in a dialog item list.
  23. // See IM I-427 for an explanation of the complete format
  24. // of a DITL
  25. */
  26. typedef struct
  27. {
  28.     long            placeholder;
  29.     Rect            location;
  30.     unsigned char    itemType;
  31.     unsigned char    extraLength;
  32. } DITLitem;
  33.  
  34. /*
  35. // Prototypes for dialogUtilities.c
  36. */
  37. void                MessageBox( Str255 pstr );
  38. void                GiveUserAChanceToCancel( Str255 pstr );
  39. void                CenterAndShowDialog(DialogPtr dlog);
  40. short                AddNewUserItem( DialogPtr dlog );
  41. pascal void            DrawDottedLineProc(DialogPtr dlog, short item);
  42. void                SetUserItemToDottedLine( DialogPtr dlog, short whichItem );
  43. pascal void            DrawFrameRectProc(DialogPtr dlog, short item);
  44. void                SetUserItemToFrameRect( DialogPtr dlog, short whichItem );
  45. pascal                void DrawDefaultProc(DialogPtr dlog, short item);
  46. short                InstallDefaultOutline(DialogPtr dlog, short button);
  47. pascal void            DrawActiveItemProc(DialogPtr dlog, short item);
  48. short                InstallActiveItemOutline(DialogPtr dlog, short button);
  49. void                MoveOutline(DialogPtr dlog, short userItem, short button);
  50. void                MoveActiveIndicator(DialogPtr dlog, short userItem, short button);
  51. void                MoveDItem( DialogPtr dlog, short itemNumber, short h, short v );
  52. void                SetItemHandle( DialogPtr dlog, short whichItem, Handle newItem );
  53. Point                GetItemPoint( DialogPtr dlog, short itemNum );
  54. Boolean                ButtonEnabled(DialogPtr dlog, short item);
  55. pascal void            EnableButton(DialogPtr dlog, short button,Boolean enable);
  56. void                FlashDlogItem( DialogPtr dlog, short itemNum );
  57. pascal Boolean        CutPasteFilter( DialogPtr dlog, EventRecord* event, short* item );
  58.  
  59. #endif
  60.